package Administrator.AdministratorMainFrame.AdministratorMainFrameController;

import Administrator.AdministratorMainFrame.AdministratorMainFrameView.*;
import Administrator.AdministratorMainFrame.AdministratorMainFrameModel.*;
import Administrator.AdministratorMainFrame.AdministratorMainFrameController.*;
import Administrator.AdministratorMainFrame.AdministratorMainFrameController.Listener.*;

public class AdministratorMainFrameController 
{
    public void initialize()
    {
    	getView().exitButton.addActionListener(new MainFrameExitButtonListener(getView(), getModel(), this));
    	
    	getView().getConfigureContestPane().getAccountsPane().getGenerateAccountsButton().
    	    addActionListener(new GenerateAccountsButtonListener());
    	
    	getView().getConfigureContestPane().getAccountsPane().getAddAccountButton().
    	addActionListener(new AddAccountsButtonListener());
    	
    	getView().getConfigureContestPane().getAccountsPane().getEditAccountButton().
    	addActionListener(new EditAccountsButtonListener());
    	
    	getView().getConfigureContestPane().getAccountsPane().getLoadAccountButton().
    	addActionListener(new LoadAccountsDataButtonListener());
    }
    public void setViewAndModel(AdministratorMainFrameView view, AdministratorMainFrameModel model)
    {
    	this.view = view;
    	this.model = model;
    }
    public AdministratorMainFrameView getView()
    {
    	return this.view;
    }
    public AdministratorMainFrameModel getModel()
    {
    	return this.model;
    }
    private AdministratorMainFrameView view;
    private AdministratorMainFrameModel model;
    
}
